//统一管理咱们项目品牌相关的接口
import request from "@/utils/request"
//项目品牌相关的请求地址
const API = {
  PRODUCT_BRAND_LIST_URL: "/super/systemProductBrand/list",
  PRODUCT_BRAND_STATUS_URL: "/super/systemProductBrand/statusChange",
  PRODUCT_BRAND_DETAIL_URL: "/super/systemProductBrand/detail",
  PRODUCT_BRAND_ADD_URL: "/super/systemProductBrand/add",
  PRODUCT_BRAND_EDIT_URL: "/super/systemProductBrand/edit",
  PRODUCT_BRAND_DEL_URL: "/super/systemProductBrand/del",
}

//获取品牌列表
export const list = (params) =>
  request.get(API.PRODUCT_BRAND_LIST_URL, { params })

//修改品牌状态
export const statusChange = (data) =>
  request.post(API.PRODUCT_BRAND_STATUS_URL, data)

//获取品牌详情
export const detail = (params) =>
  request.get(API.PRODUCT_BRAND_DETAIL_URL, { params })

//添加品牌
export const create = (data) =>
  request.post(API.PRODUCT_BRAND_ADD_URL, data)

//修改品牌
export const update = (data) =>
  request.post(API.PRODUCT_BRAND_EDIT_URL, data)

//删除品牌
export const destroy = (data) =>
  request.post(API.PRODUCT_BRAND_DEL_URL, data)
